home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
SGI Performance Co-Pilot 1.3
/
SGI Performance Co-Pilot 1.3.iso
/
dist
/
pcp_gifts.idb
/
usr
/
sbin
/
pmsocks.z
/
pmsocks
Wrap
Text File
|
1997-04-03
|
684b
|
38 lines
#! /bin/sh
#
# $Id: pmsocks.sh,v 2.1 1997/03/26 03:13:11 kenmcd Exp $
# Dynamically sockify the argument program
#
if [ $# -eq 0 ]
then
echo Usage: $0 \[path\]program \[args ...\]
exit 1
fi
if [ -z "$SOCKS_SERVER" ]
then
echo $0: SOCKS_SERVER is not set in the environment
exit 1
fi
if [ ! -f /etc/pcp_socks.conf -a ! -l /etc/pcp_socks.conf ]
then
echo $0: /etc/pcp_socks.conf does not exist
exit 1
fi
if [ ! -f /usr/pcp/lib/libpcp_socks.so ]
then
echo $0: can not find /usr/pcp/lib/libpcp_socks.so
exit 1
fi
program=$1
shift
args="$*"
_RLD_LIST=/usr/pcp/lib/libpcp_socks.so:DEFAULT
export SOCKS_SERVER SOCKS_BANNER _RLD_LIST
exec $program $args